A two-dimension code, also known as a two-dimension bar code, is another dimension readable bar code obtained by performing extension based on a one-dimension bar code. The two-dimension code is a black alternating with white figure distributed on a plane (two-dimension direction) by using specific geometric figures according to certain laws, and is a key of all information data. Currently, because the two-dimension code has features of large information storage capacity, high confidentiality, and low costs, the two-dimension code is gradually applied and popularized in fields such as industry and commerce, communications and transportation, finance, and medical treatment. However, in recent years, a mobile terminal two-dimension code service flourished in the field of mobile communications makes mobile terminal users enter an era in which information is readily available, and great business opportunities brought thereby become more apparent at home and abroad.
Currently, many remote servers provide a function of two-dimension code login. When a user uses an application program having permission requirements provided by a remote server, the user may photograph a two-dimension code image provided by the application program by using an own camera of a mobile terminal first, parse out verification information in the two-dimension code image, then send the two-dimension code verification information and login information preset in the mobile terminal to the remote server, and directly successfully log in to the application program by using the login information after the remote server verifies and passes the two-dimension code verification information.
This way of logging by using the two-dimension code not only may get rid of a traditional series of complex operations such as inputting an account number and a password, which is convenient and quick, but also may effectively prevent trojan horse from monitoring a keyboard to steal the input password, so that leakage of user information on the mobile terminal may be avoided to some degree. However, there are still certain potential security problems in the way of two-dimension code login. If the two-dimension code image provided by the application program is replaced by a trojan horse program with a malicious two-dimension code image, leakage of personal information may still be caused. For example, after scanning the replaced two-dimension code image, the mobile terminal may access a malicious website server according to information in the two-dimension code image, and send the personal information in the mobile terminal, such as the account number and the password to the malicious server, thereby causing the leakage of the user information and even losses of private property.